#include "hero.h"

Hero::Hero()
{
	x = 0;
	y = 0;
}

char 
Hero::Char(TCODColor* color)
{
	*color = TCODColor::lightGrey;
	return '@';
}


void 
Hero::Act(TCOD_keycode_t key)
{
	switch(key)
	{
		case TCODK_KP1:
			--x; ++y;
			break;
		case TCODK_KP2: case TCODK_DOWN:
			++y;
			break;
		case TCODK_KP3:
			++x; ++y;
			break;
		case TCODK_KP4: case TCODK_LEFT:
			--x;
			break;
		case TCODK_KP6: case TCODK_RIGHT:
			++x;
			break;
		case TCODK_KP7:
			--x; --y;
			break;
		case TCODK_KP8: case TCODK_UP:
			--y;
			break;
		case TCODK_KP9:
			++x; --y;
			break;
		default:
			break;
	}
}
